<template>
  <div>
    <h2>axios</h2>
    <el-button type="primary">按钮</el-button>
    <div class="md"></div>
  </div>
</template>
<script lang="ts" setup>
import { getCurrentInstance, onMounted } from "vue";
const { proxy } = getCurrentInstance()!;
import { getWeather } from "@/api/index";
import doc from "./test.md";
onMounted(() => {
  getData();
  console.log("doc", doc);
  document.querySelector(".md")!.innerHTML = doc;
});

async function getData() {
  const res =  await getWeather({
    city: "北京"
  },{showLoading: true})
  console.log("res", res);
}
</script>
